package com.gxa.auth;


import lombok.Data;
import org.apache.shiro.authc.AuthenticationToken;

/**
 * token
 *
 */
@Data
public class OAuth2Token implements AuthenticationToken {
    /** token密匙*/
    private String token;
    /** 过期时间*/
    private String exipreAt;


    public OAuth2Token(String token) {
        this.token = token;
    }

    public OAuth2Token(String token, String exipreAt) {
        this.token = token;
        this.exipreAt = exipreAt;
    }

    @Override
    public Object getPrincipal() {
        return token;
    }

    @Override
    public Object getCredentials() {
        return token;
    }
}
